package dup.login.demo.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.*;

//@Controller
@RestController
@RequestMapping(value = "/hello")
public class HelloController {
    //@RequestMapping(value = "/sayhello", method = RequestMethod.GET)
    //@GetMapping(value = {"/sayhello", "hi"})
    @PostMapping("/sayhello")
    //@ResponseBody
    public String sayHello(@RequestParam(value = "name", required = true, defaultValue = "") String name) {
        return "Hello Spring Boot!" + name;
    }
}
